package day07;
//蜗牛爬井
public class Snail {
    public static void main(String[] args) {
        int day=0;//天数
        int total=0;//计算当前爬了多少米
        int dayTime=3;
        int night=2;
       while (true){
           day++;
           total+=dayTime;

           if(total>=10){

               System.out.println(total);
               System.out.println(day);
               break;
           }
           total-=night;

       }
    }
}
